home *** CD-ROM | disk | FTP | other *** search
/ Technotools / Technotools (Chestnut CD-ROM)(1993).ISO / lang_c / ctb100t / manual.doc < prev    next >
Text File  |  1987-08-28  |  40KB  |  1,298 lines

  1. .mt 8
  2. .he
  3. .op
  4.  
  5.  
  6. 
  7.                            C Tool Box
  8.  
  9.  
  10.  
  11.  
  12.  
  13.  
  14.  
  15.  
  16.  
  17.  
  18.  
  19.  
  20.  
  21.                    A Library of Functions for
  22.                           Turbo C 1.00
  23.  
  24.                    Containing Graphics, Fonts,
  25.                 Windows, Sound, Background Sound
  26.               Mouse, Joystick and Printer Controls
  27.                             and more
  28.  
  29.  
  30.  
  31.  
  32.                          Version 1.00 
  33.                    release date 22 August 1987
  34.  
  35.  
  36.  
  37.  
  38.  
  39.  
  40.  
  41.  
  42.  
  43.  
  44.                        Copyright (c) 1987
  45.                                by
  46.                         David A.  Miller
  47.                         Unicorn Software
  48.                         8018 NE 123rd St.
  49.                        Kirkland, WA 98034
  50.                   (206) 823-4656 after 6:30 PM
  51.                         Pacific Time Zone
  52.                     (No collect calls Please)
  53. è
  54.  
  55. 
  56.  
  57. Welcomσá t∩ thσ realφ oµ thσ mystica∞ Unicorn«á  I⌠ ha≤á beeεá aε ì
  58. enjoyablσá proces≤ creatinτ thi≤ librar∙ anΣ thσ autho≥ hope≤ yo⌡ ì
  59. find it equally enjoyable to use.
  60. 
  61.  
  62.  
  63.  
  64.                            Disclaimer
  65.  
  66. Thσ autho≥ ha≤ takeε duσ carσ iε thσ preparatioε oµ thi≤ manua∞ ì
  67. anΣ thσ associateΣ program≤ t∩ insurσ tha⌠ al∞ informatioε ì
  68. presenteΣ i≤ correc⌠ anΣ functiona∞ a≤ stated«  N∩ warrant∙ i≤ ì
  69. madσ regardinτ thσ suitabilit∙ oµ thi≤ produc⌠ fo≥ an∙ specifiπ ì
  70. purpose.  Consisten⌠ witΦ thσ requiremen⌠ oµ speeΣ iε mucΦ oµ ì
  71. thσ librar∙ anΣ thσ genera∞ philosoph∙ oµ ├ iε allowinτ thσ ì
  72. programme≥ completσ freedom¼ thσ amoun⌠ oµ erro≥ checkinτ ha≤ ì
  73. beeε helΣ t∩ ß minimum.
  74.  
  75.   Thσ autho≥ hereb∙ grant≤ permissioε t∩ al∞ user≤ t∩ transfe≥ ì
  76. copie≤ oµ thσ librar∙ t∩ thirΣ partie≤ subjec⌠ t∩ thσ condition≤ ì
  77. tha⌠ thσ entirσ librar∙ anΣ al∞ file≤ includinτ copyright≤ bσ ì
  78. transferreΣ iε ful∞ fo≥ n∩ feσ execep⌠ iε thσ casσ oµ user≤ group≤ ì
  79. whicΦ ma∙ chargσ ß copyinτ feσ no⌠ t∩ exceeΣ $7.00.
  80.  
  81.   Whilσ yo⌡ ma∙ usσ thσ librar∙ fo≥ persona∞ program≤ withou⌠ ì
  82. registration¼ thosσ wh∩ creatσ program≤ fo≥ salσ o≥ distributioε ì
  83. arσ requesteΣ t∩ registe≥ thei≥ copy«  Thσ sourcσ codσ ma∙ NO╘ bσ ì
  84. distributeΣ t∩ ß thirΣ part∙ iε an∙ forφ withou⌠ thσ writteε ì
  85. permissioε oµ thσ author.
  86.  
  87.  
  88.  
  89.  
  90.  
  91.  
  92. Turb∩ ├ i≤ ß trademarδ oµ BorlanΣ International¼ Microsof⌠ C¼ ì
  93. MAS═ anΣ MSDO╙ arσ trademark≤ oµ Microsof⌠ Corp«  IBM¼ IB═ PC¼ ì
  94. P├ XT¼ AT¼ DO╙ anΣ PCDO╙ arσ trademark≤ oµ Internationa∞ Busines≤ ì
  95. Machine≤ Corp.¼ Epsoε i≤ ß trademarδ oµ Epsoε Corp« Tandy¼ Tand∙ ì
  96. 1000 A and DMP 130 are trademarks of Tandy Corp.ì
  97.  
  98. .paè.he C_Tool_Box_______________________________________________Page_#
  99.                            Background
  100. 
  101.  
  102.    Thi≤ librar∙ i≤ thσ successo≥ t∩ thσ origina∞ Unicorε Librar∙ ì
  103. whicΦ ha≤ undergonσ severa∞ revision≤ anΣ essentiall∙ ha≤ becomσ ì
  104. ß ne≈ entity«  Somσ oµ thσ curren⌠ revision≤ concerε simplσ ì
  105. orderinτ oµ thσ parameter≤ iε call≤ t∩ makσ thσ librar∙ morσ ì
  106. consistent«  User≤ oµ thσ Unicorε librar∙ shoulΣ takσ particula≥ ì
  107. notσ oµ thi≤ point«  Function≤ havσ beeε developeΣ fo≥ whicΦ thσ ì
  108. autho≥ ha≤ n∩ specifiπ neeΣ bu⌠ founΣ interestinτ t∩ implement«  ì
  109. Man∙ oµ thσ function≤ arσ ß resul⌠ oµ use≥ suggestion≤ fo≥ whicΦ ì
  110. wσ thanδ thσ user≤ involved«  Thσ autho≥ invite≤ user≤ t∩ makσ ì
  111. furthe≥ suggestions¼ a≤ ß worthwilσ challengσ i≤ alway≤ aε ì
  112. interestinτ learninτ experience.
  113.    
  114.    Thi≤ librar∙ contain≤ function≤ t∩ perforφ ß widσ variet∙ oµ ì
  115. task≤  Thσ function≤ ma∙ bσ divideΣ roughl∙ int∩ thσ followinτ ì
  116. categories:
  117.  
  118. 1«  Genera∞ vide∩ includinτ window≤ anΣ fas⌠ strinτ writes.
  119. 2«  Graphics¼ includinτ ß variet∙ oµ norma∞ anΣ rotateΣ fonts
  120. 3«  SounΣ includinτ backgrounΣ sounΣ function≤ simila≥ t∩ BASIC
  121. 4«  Genera∞ function≤ servinτ ß widσ variet∙ oµ purposes
  122. 5«  Printe≥ control¼ botΦ graphic≤ anΣ dais∙ wheel
  123. 6«  Mousσ control
  124. 7«  Joysticδ control
  125.   
  126.    EacΦ oµ thesσ grouping≤ overlap≤ t∩ somσ exten⌠ bu⌠ iε genera∞ ì
  127. all¼ excep⌠ thσ graphic≤ iε grou≡ 2¼ ma∙ bσ useΣ witΦ ß ì
  128. monochromσ system« Thσ genera∞ librar∙ i≤ designeΣ t∩ bσ useΣ ì
  129. witΦ Turb∩ ├ froφ BorlanΣ anΣ program≤ writteε usinτ thσ smal∞ ì
  130. memor∙ model«  Othe≥ compiler≤ arσ supporteΣ anΣ librarie≤ ma∙ bσ ì
  131. requesteΣ froφ thσ autho≥ upoε registration«  Iε additioε t∩ thi≤ ì
  132. basiπ library¼ thosσ availablσ includσ thσ largσ mode∞ fo≥ Turb∩ ì
  133. ├ anΣ botΦ model≤ fo≥ Microsof⌠ ├ ¿ Curren⌠ versioε )«  Thσ ì
  134. autho≥ wil∞ als∩ makσ ß Latticσ ├ versioε 3.░ librar∙ availablσ ì
  135. iµ therσ arσ enougΦ requests«  Whilσ thesσ arσ thσ basiπ ì
  136. compiler≤ thσ autho≥ ha≤ acces≤ to¼ other≤ ma∙ bσ supporteΣ iµ ì
  137. thσ numbe≥ oµ request≤ warrant.
  138.  
  139.   Thσ entirσ manua∞ i≤ no⌠ supplieΣ witΦ thσ Bulletiε BoarΣ ì
  140. versioε oµ thσ librar∙ duσ t∩ space«  EnougΦ oµ thσ manua∞ i≤ ì
  141. includeΣ t∩ makσ thσ librar∙ usablσ includinτ ß brieµ descriptioε ì
  142. oµ eacΦ functioε anΣ ß cal∞ iε ß forφ simila≥ t∩ functioε ì
  143. prototyping«  Thσ entirσ manua∞ i≤ availablσ oε disδ iε Wordsta≥ ì
  144. o≥ ASCI╔ tex⌠ forma⌠ anΣ wil∞ bσ sen⌠ t∩ al∞ registereΣ owner≤ ì
  145. (pleasσ specif∙ whicΦ format)«  PreprinteΣ manual≤ arσ availablσ ì
  146. fo≥ thosσ wh∩ don'⌠ wisΦ t∩ prin⌠ ove≥ 20░ pages«  Seσ thσ ì
  147. registratioε forφ fo≥ details«  
  148. .paè                       First Things First
  149. 
  150.  
  151. Iµ yo⌡ havσ registereΣ you≥ librar∙ anΣ havσ thσ ful∞ sourcσ ì
  152. distributioε disks¼ yo⌡ shoulΣ havσ onσ disδ oµ ├ sourcσ codσ anΣ ì
  153. headers¼ onσ oµ AS═ sourcσ codσ anΣ eithe≥ ß disδ containinτ thσ ì
  154. manua∞ o≥ thσ preprinteΣ manua∞.
  155.  
  156. Checδ you≥ disk≤ t∩ insurσ tha⌠ al∞ file≤ arσ readable«  Therσ ì
  157. shoulΣ bσ 1┤ ├ sourcσ files¼ 1┤ AS═ sourcσ file≤ anΣ │ heade≥ ì
  158. file≤ a≤ oµ thi≤ writing«  Thi≤ amount≤ t∩ ove≥ 500╦ oµ sourcσ ì
  159. code«  
  160.  
  161. Therσ i≤ n∩ particula≥ installatioε proces≤ fo≥ thi≤ library«  I⌠ ì
  162. i≤ read∙ t∩ usσ a≤ is«  Simpl∙ placσ thσ librar∙ iε thσ director∙ ì
  163. with the other libraries you use with your compiler.
  164.  
  165. Man∙ oµ thσ critica∞ function≤ havσ beeε codeΣ iε assemble≥ fo≥ ì
  166. speed«  Somσ oµ thσ presen⌠ function≤ codeΣ iε ├ (thσ font≤ ì
  167. remaininτ iε ├ anΣ rotateΣ font≤ iε particular⌐ wil∞ bσ codeΣ iε ì
  168. assemble≥ iε futurσ revisions«  Therσ arσ ß fe≈ instance≤ wherσ ì
  169. function≤ perforφ simila≥ task≤ bu⌠ arσ codeΣ differently«  Fo≥ ì
  170. example¼ therσ i≤ botΦ aε assemble≥ anΣ ß ├ functioε t∩ se⌠ thσ ì
  171. vide∩ mode«  Somσ oµ thesσ havσ beeε lef⌠ a≤ learninτ tool≤ fo≥ ì
  172. thσ use≥ a≤ the∙ illustratσ botΦ approache≤ t∩ solutioε oµ ß ì
  173. particula≥ task«  Sincσ thi≤ librar∙ wa≤ beguε a≤ ß learninτ ì
  174. project¼ i⌠ i≤ fel⌠ thσ use≥ ma∙ benefi⌠ froφ sucΦ material«  
  175.  
  176. Makσ ß backu≡ cop∙ beforσ yo⌡ d∩ anythinτ else«  Thσ disk≤ arσ ì
  177. no⌠ copy-protectedé iε an∙ manner«  Also¼ i⌠ woulΣ bσ helpfu∞ iµ ì
  178. yo⌡ reaΣ thσ filσ READ.M┼ a≤ i⌠ contain≤ thσ lates⌠ informatioε ì
  179. concerninτ thσ library«  Wherσ thi≤ manua∞ anΣ READ.M┼ conflict¼ ì
  180. pleasσ regarΣ thσ READ.M┼ filσ a≤ beinτ thσ mos⌠ curren⌠ ì
  181. information«  
  182.  
  183. Therσ arσ dem∩ program≤ oε thσ disk¼ thσ larges⌠ beinτ CTDEMO.EX┼ ì
  184. anΣ CTDEMO.C«  Thi≤ wa≤ compileΣ witΦ thσ librar∙ oε thσ ì
  185. distributioε disk≤ anΣ illustrate≤ thσ capabilit∙ oµ thσ librar∙ ì
  186. itselµ althougΦ i⌠ b∙ n∩ mean≤ use≤ o≥ illustrate≤ ever∙ functioε ì
  187. iε thσ library.
  188.  
  189. Thσ library¼ a≤ delivereΣ normally¼ i≤ thσ smal∞ memor∙ mode∞ oµ ì
  190. Turb∩ C¼ anΣ al∞ references¼ unles≤ otherwisσ stated¼ wil∞ refe≥ ì
  191. t∩ tha⌠ configuration.
  192.  
  193. Therσ arσ ove≥ 20░ functionsé containeΣ withiε thσ ├ Too∞ Bo° anΣ ì
  194. therσ i≤ ß shor⌠ referencσ sectioε givinτ ß brieµ samplσ cal∞ anΣ ì
  195. descriptioε oµ eacΦ functioε late≥ iε thσ manual«  Thσ ì
  196. comprehensivσ sectioε followinτ tha⌠ give≤ ß completσ call¼ ì
  197. paramete≥ description¼ samplσ prograφ o≥ codσ fragmen⌠ ìèillustratinτ thσ fuction≤ usage¼ return≤ anΣ an∙ caveat≤ tha⌠ ma∙ ì
  198. occu≥ witΦ tha⌠ function.
  199.  
  200. Al∞ oµ thσ function≤ wil∞ perforφ correctl∙ witΦ IB═ PC'≤ o≥ ì
  201. closσ compatibles¼ bu⌠ bσ awarσ tha⌠ fo≥ severa∞ oµ thσ critica∞ ì
  202. timinτ function≤ direc⌠ screeε writinτ i≤ useΣ t∩ improvσ ì
  203. performance«  Unles≤ you≥ machinσ addresse≤ vide∩ memor∙ iε thσ ì
  204. samσ manne≥ a≤ thσ IBM¼ ß probleφ ma∙ exist«  Thσ librar∙ wa≤ ì
  205. writteε oε ß Tand∙ 100░ ┴  anΣ ha≤ beeε ruε oε severa∞ othe≥ ì
  206. machine≤ witΦ completσ success.
  207.  
  208. Al∞ function≤ beginninτ witΦ d° arσ designeΣ t∩ suppor⌠ ß dais∙ ì
  209. whee∞ printer«  The∙ werσ developeΣ oε ß Epsoε printe≥ tha⌠ i≤ ì
  210. compatiblσ witΦ thσ DW-630«  Al∞ function≤ begininτ witΦ g≥ arσ ì
  211. designeΣ t∩ suppor⌠ thσ IB═ graphic≤ printe≥ o≥ compatible«  ì
  212. Thesσ werσ developeΣ oε ß TAND┘ DM╨ 130«  
  213.  
  214. Thosσ wh∩ arσ registereΣ owner≤ anΣ havσ thσ sourcσ codσ wil∞ ì
  215. finΣ tha⌠ onl∙ fou≥ function≤ neeΣ t∩ bσ altereΣ t∩ suppor⌠ othe≥ ì
  216. graphic≤ systems«  Thesσ arσ thσ tw∩ do⌠ routine≤ (interna∞ anΣ ì
  217. external⌐ anΣ thσ tw∩ function≤ t∩ returε thσ colo≥ oµ ß pixe∞ ì
  218. (interna∞ anΣ external)«  Al∞ othe≥ function≤ arσ baseΣ oε thesσ ì
  219. t∩ makσ conversioε easier«  Thσ autho≥ doe≤ no⌠ havσ acces≤ t∩ ß ì
  220. Hercule≤ systeφ fo≥ thi≤ conversion«  ┴ conversioε t∩ thσ EG┴ i≤ ì
  221. currentl∙ underwa∙ althougΦ acces≤ t∩ aε EG┴ systeφ i≤ ver∙ ì
  222. limiteΣ fo≥ testinτ purposes.
  223.  
  224.  
  225. 
  226.                           Update Policy
  227.  
  228. I⌠ i≤ thσ polic∙ oµ Unicorε Softwarσ t∩ providσ onσ freσ updatσ ì
  229. fo≥ thσ librar∙ itselµ (no⌠ thσ sourcσ codσ whicΦ ma∙ bσ updateΣ ì
  230. fo≥ ß smal∞ fee⌐ anΣ notificatioε oµ onσ updatσ beyonΣ that«  Iµ ì
  231. thσ ne≈ librar∙ i≤ registereΣ fo≥ thσ updatσ fee¼ theε wσ wil∞ ì
  232. star⌠ thσ proces≤ ove≥ agaiε anΣ yo⌡ wil∞ agaiε receivσ onσ freσ ì
  233. updatσ anΣ onσ notificatioε beyonΣ tha⌠ point«  Thi≤ insure≤ ì
  234. user≤ wh∩ registe≥ wil∞ alway≤ havσ acces≤ t∩ thσ lates⌠ versioε ì
  235. oµ thσ Too∞ Box«  Mino≥ release≤ wil∞ bσ placeΣ oε bulletiε ì
  236. board≤, bu⌠ registereΣ user≤ wil∞ no⌠ bσ notifieΣ directl∙ unles≤ ì
  237. the∙ s∩ request« (I⌠ i≤ fel⌠ tha⌠ mos⌠ woulΣ prefe≥ t∩ usσ thσ ì
  238. freσ updatσ fo≥ ß majo≥ release)«  Currentl∙ thσ autho≥ place≤ ì
  239. copie≤ oµ thσ Too∞ Bo° (majo≥ anΣ mino≥ releases⌐ directl∙ oε thσ ì
  240. followinτ board≤ iε thσ Seattlσ area.
  241.  
  242. 1.  Journey to Mars      (RBBS)  206  486-3136
  243. 2.  Night Shift          (RBBS)  206  488-0924
  244. 3.  Planet Claire        (RBBS)  206  783-8037
  245. 4.  PNW IBM user group   (RBBS)  206  343-7843
  246. è
  247.  
  248. Thσ autho≥ log≤ oε witΦ thσ namσ 'Davσ Millerº oε eacΦ oµ thesσ ì
  249. boards.
  250.  
  251. Thσ mos⌠ likel∙ spo⌠ t∩ finΣ thσ autho≥ fo≥ feedbacδ woulΣ bσ ì
  252. Journey to Mars or Nightshift.
  253.  
  254.  
  255. 
  256.                         Programming Style
  257. 
  258.  
  259. Thσ sourcσ codσ i≤ writteε iε standarΣ ╦ ª ╥ witΦ onσ deviation«  ì
  260. Thσ autho≥ prefer≤ thσ openinτ anΣ closinτ brace≤ t∩ linσ u≡ s∩ ì
  261. insteaΣ of:
  262.  
  263.                if (i = 2) {
  264.                     printf("I = 2");
  265.                }
  266.  
  267. you will find:
  268.  
  269.                if (i = 2)
  270.                {
  271.                   printf("I = 2");
  272.                }
  273.  
  274. in the source code for the Tool Box.
  275.  
  276. 
  277.                     Declaration of Functions
  278. 
  279.  
  280. Mos⌠ function≤ arσ eithe≥ voiΣ o≥ returε int« I⌠ i≤ no⌠ strictl∙ ì
  281. requireΣ t∩ declarσ theφ prio≥ t∩ use«  I⌠ i≤ GOO─ PROGRAMMIN╟ ì
  282. PRACTICEé t∩ declarσ al∞ function≤ prio≥ t∩ use«  Thi≤ practicσ ì
  283. wil∞ avoiΣ problem≤ witΦ thσ fe≈ function≤ whicΦ d∩ returε ß ì
  284. differen⌠ value¼ sucΦ a≤ ß pointe≥ t∩ ß window«  
  285.  
  286.  
  287.  
  288.  
  289.  
  290.  
  291. .paè                           Technical
  292. 
  293. Thi≤ librar∙ wa≤ createΣ usinτ thσ followinτ tools.
  294.  
  295.      Turb∩ ├ 1.00
  296.      Microsof⌠ Linδ 3.51
  297.      MAS═ 4.0
  298.      Microsof⌠ Librar∙ Manage≥ 3.02
  299.  
  300.  
  301. Thσ module≤ useΣ anΣ thσ orde≥ the∙ shoulΣ appea≥ iε thσ librar∙ ì
  302. ma∙ bσ founΣ b∙ usinτ LI┬ t∩ creatσ aε LS╘ filσ oµ thσ library«  ì
  303. Iµ yo⌡ registe≥ anΣ wisΦ t∩ recompilσ fo≥ ß differen⌠ memor∙ ì
  304. mode∞ o≥ compile≥, thi≤ orde≥ shoulΣ bσ preserved.
  305.  
  306. A⌠ presen⌠, ß smal∞ buτ exist≤ iε thσ endsounΣ function«  I⌠ wil∞ ì
  307. bσ bes⌠ iµ yo⌡ le⌠ backgrounΣ sounΣ ruε it≤ course¼ anΣ no⌠ ì
  308. attemp⌠ t∩ sto≡ i⌠ witΦ thi≤ command«  Thi≤ wil∞ bσ fixeΣ iε thσ ì
  309. nex⌠ majo≥ releasσ ¿ Jaε 198╕ )«  RegistereΣ owner≤ wil∞ ì
  310. automaticall∙ receivσ thσ ne≈ sourcσ fo≥ thi≤ functioε witΦ thei≥ ì
  311. freσ updatσ disk.
  312.  
  313. Revision≤ arσ possiblσ iε somσ function≤ iε thσ nex⌠ release«  ì
  314. Ever∙ possiblσ effor⌠ wil∞ bσ useΣ t∩ maintaiε FUL╠ ì
  315. compatibility¼ bu⌠ bσ awarσ tha⌠ thσ call≤ t∩ somσ windo≈ ì
  316. function≤ anΣ t∩ thσ backgrounΣ sounΣ function≤ ma∙ bσ altereΣ ì
  317. somewhat«  Wheε usinτ thσ Too∞ Bo° pleasσ kee≡ thi≤ iε minΣ iµ ì
  318. yo⌡ plaε t∩ upgrade«  I⌠ i≤ anticipateΣ thσ change≤ wil∞ no⌠ bσ ì
  319. extensivσ anΣ additiona∞ function≤ wil∞ bσ addeΣ whereve≥ ì
  320. possiblσ rathe≥ thaε alterinτ thσ existinτ functions«  Thσ autho≥ ì
  321. wil∞ preservσ al∞ curren⌠ functioε call≤ intac⌠ iε al∞ release≤ ì
  322. beyonΣ thi≤ point.
  323.  
  324. .paè                       Your First Program
  325. 
  326.  
  327.   Usinτ thσ ├ Too∞ Boxé i≤ essentiall∙ quitσ simple«  WitΦ Turb∩ ├ ì
  328. yo⌡ mus⌠ specif∙ an∙ module≤ t∩ bσ linkeΣ iε you≥ projec⌠ file«  ì
  329. Iµ the∙ arσ no⌠ ├ file≤ theε thσ completσ extensioε mus⌠ bσ used«  ì
  330. Fo≥ examplσ supposσ yo⌡ wisΦ t∩ builΣ ß filσ 'mytest.exeº froφ ì
  331. mytest.π anΣ thσ ├ Too∞ Boxé library«  You≥ projec⌠ filσ shoulΣ bσ ì
  332. iε ß forφ simila≥ t∩ thσ below:
  333.  
  334.  
  335.                              mytest
  336.                              CTB100.LIB
  337.  
  338.  
  339. Wheε yo⌡ arσ withiε thσ Turb∩ ├ environmen⌠, simply usσ Al⌠ ╨ t∩ ì
  340. indicatσ thσ projec⌠ filσ namσ anΣ theε Al⌠ ╥ t∩ builΣ anΣ ruε ì
  341. you≥ program«  Yo⌡ ma∙ als∩ builΣ you≥ prograφ froφ thσ commanΣ ì
  342. linσ b∙ typing:
  343.  
  344.                       TC├ mytes⌠ CTB100.lib
  345.  
  346.  
  347. Eithe≥ approacΦ wil∞ builΣ you≥ prograφ anΣ linδ i⌠ witΦ thσ ├ ì
  348. Too∞ Boxé librar∙.
  349.  
  350.  
  351. Thσ dem∩ prograφ wa≤ buil⌠ usinτ thσ command:
  352.  
  353.                      TC├ CTDEM╧ CTB100.LIB
  354.  
  355. Therσ i≤ ß projec⌠ filσ oε thσ disδ iµ yo⌡ prefe≥ t∩ worδ withiε ì
  356. thσ Turb∩ ├ environment«  Thσ dem∩ ma∙ bσ buil⌠ b∙ specifyinτ ì
  357. ctdem∩ a≤ thσ filσ anΣ ctdemo.prΩ a≤ thσ projec⌠ file«  Usσ AL╘ ≥ ì
  358. t∩ ruε thσ prograφ o≥ AL╘ π t∩ compilσ it.
  359.  
  360. .paè                           The Future
  361. 
  362.  
  363. Thσ nex⌠ majo≥ releasσ i≤ planneΣ fo≥ Jaε., 1988«  Somσ ì
  364. of the ideas being considered and/or worked on are:
  365.      
  366.      1.  Animation functions
  367.      2.  Data entry functions
  368.      3.  Menu functions (including pulldown)
  369.      4.  Additional window functions
  370.      5«  Additiona∞ sounΣ functions
  371.      6«  Font≤ - rewrittinτ thosσ lef⌠ codeΣ iε ├ iε assemble≥          ì
  372.          fo≥ speeΣ anΣ ß truσ strokσ fon⌠ capability«  Thi≤ wa≤           ì
  373.          containeΣ iε thσ origina∞ Latticσ ├ version╗  Thσ autho≥
  374.          woulΣ likσ t∩ restorσ i⌠ witΦ ful∞ rotation¼ 
  375.          translatioε anΣ scalinτ fo≥ thσ nex⌠ majo≥ release.
  376.  
  377.      
  378. Thσ autho≥ wishe≤ t∩ continuσ providinτ thi≤ librar∙ t∩ user≤ iε ì
  379. thσ forφ oµ sharewarσ consisten⌠ witΦ use≥ support«  I⌠ ha≤ beeε ì
  380. aε enjoyablσ sparσ timσ projec⌠ ove≥ thσ las⌠ yea≥ anΣ ß half« ì
  381. Thσ autho≥ feel≤ sharewarσ i≤ aε importan⌠ elemen⌠ iε today'≤ ì
  382. compute≥ environment.
  383.  
  384. Pleasσ fee∞ freσ t∩ expres≤ you≥ opinioε oε wha⌠ yo⌡ wisΦ t∩ seσ ì
  385. madσ available«  Le⌠ u≤ know!
  386.  
  387. .paè                    Interna∞ Globa∞ Variables
  388. 
  389.  
  390.    The librar∙ contains a serie≤ oµ globa∞ variables«  Yo⌡ ì
  391. shoulΣ no⌠ usσ thesσ name≤ iε you≥ program≤ unles≤ yo⌡ ì
  392. specificall∙ wisΦ t∩ referencσ tha⌠ variable«  Fo≥ examplσ usinτ ì
  393. ß variablσ nameΣ bdr▒ iε you≥ prograφ wil∞ resul⌠ iε ß linδ erro≥ ì
  394. a⌠ bes⌠ o≥ failurσ oµ thσ windowinτ function≤ tha⌠ usσ borde≥ ▒ ì
  395. a⌠ worst«  Belo≈ i≤ ß lis⌠ oµ thesσ variable≤ anΣ thei≥ interna∞ ì
  396. meaning≤ t∩ thσ library.
  397.  
  398. int       BLACK          the color black
  399. int       BLUE           the color blue
  400. int       GREEN          the color green
  401. int       CYAN           the color cyan
  402. int       RED            the color red
  403. int       MAGENTA        the color magenta
  404. int       BROWN          the color brown
  405. int       GRAY           the color gray
  406. int       GREY           the color gray
  407. int       WHITE          the color gray
  408. int       DARK_GRAY      the color dark gray
  409. int       DARK_GREY      the color dark gray
  410. int       LTBLUE         the color light blue
  411. int       LTGREEN        the color light green
  412. int       LTCYAN         the color light cyan
  413. int       LTRED          the color light red
  414. int       LTMAGENTA      the colorlight magenta
  415. int       LTBROWN        the color yellow
  416. int       YELLOW         the color yellow
  417. int       LTWHITE        the color light or bright white
  418.  
  419. int       NORMAL         the normal monochrome attribute
  420. int       UNDERLINE      the underline monochrome attribute
  421. int       REVERSE        the reverse video monochrome attribute
  422. int       BRIGHT         the highlighted monochrome attribute
  423. int       BLINK          monochrome blink bit indicator
  424.  
  425. int       v_start        starting address for video memory
  426. int       ct_mode_       current video mode
  427. int       ct_col_        current number of video columns
  428. in⌠       ct_color▀      indicate≤ iµ colo≥ i≤ alloweΣ (1⌐ o≥ no⌠ ì
  429.  
  430. BORDER    bdr1           a single line border for windows
  431. BORDE╥    bdr1▓          ß borde≥ witΦ ß singlσ vertica∞ linσ anΣ 
  432.                          double horizontal lines.
  433. BORDE╥    bdr2▒          ß borde≥ witΦ doublσ vertica∞ line≤ anΣ 
  434.                          a single horizontal line
  435. BORDER    star           a border of "*" characters
  436. BORDER    dot            a border of "." charactersèBORDER    solid          a border of solid blocks ( char 219)
  437. BORDER    heart          a border of heart characters
  438. BORDER    space          a blank border of space characters
  439.  
  440.                          NOTE - The default border is a double
  441.                                 line.
  442.                                 BORDE╥ i≤ ß pointe≥ t∩ ß borde≥. 
  443.                                 WINDOW is a pointer to a box, 
  444.                                 generall∙ indicateΣ b∙ 'bpº iε 
  445.                                 documentation.
  446.             
  447.  
  448. Seσ thσ heade≥ CTB.╚ fo≥ additiona∞ variable≤ anΣ define≤ tha⌠ ì
  449. ma∙ bσ useful.
  450.  
  451.  
  452.                          
  453. .paè                        Registration Form
  454. 
  455.    Thi≤ librar∙ i≤ distributeΣ a≤ sharewarσ whicΦ simpl∙ mean≤ ì
  456. yo⌡ arσ freσ t∩ copy¼ usσ anΣ pas≤ copie≤ oε t∩ friend≤ fo≥ ì
  457. evaluation«  Iµ yo⌡ decidσ i⌠ i≤ useful¼ yo⌡ ma∙ registe≥ you≥ ì
  458. cop∙ witΦ thσ author«  Upoε registratioε yo⌡ wil∞ receivσ thσ ì
  459. completσ sourcσ codσ fo≥ thσ librar∙ anΣ ß cop∙ oµ thσ manua∞ oε ì
  460. disk«  Thi≤ wil∞ consis⌠ oµ │ disks«  Iε additioε yo⌡ wil∞ ì
  461. receivσ thσ firs⌠ updatσ disδ freeé anΣ notificatioε oµ an∙ ì
  462. furthe≥ updates«  Majo≥ releasσ update≤ arσ occurinτ abou⌠ │ ì
  463. time≤ ß year.
  464.  
  465. Thσ curren⌠ registratioε feσ i≤ $29.95é   
  466.  
  467.  
  468. Name:             ______________________________________________
  469.  
  470. Computer Type:    ______________________________________________
  471.  
  472. Address:          ______________________________________________
  473.  
  474.                   ______________________________________________
  475.  
  476. City/State/Zip:   _________________________  ____  _____________
  477.  
  478. Library Version:  _CTB_1.00___________________________________
  479.  
  480. Compiler: (check 1)
  481.                   Turbo C ___  Microsoft C ___  other __________
  482.  
  483. Morσ thaε onσ versioε ma∙ bσ requested«  Pleasσ adΣ aε updatσ fee
  484. oµ $12.95 fo≥ eacΦ additiona∞ version.
  485.  
  486. PreprinteΣ manua∞ page≤ suitablσ fo≥ placemen⌠ iε ß threσ rinτ ì
  487. binde≥ wil∞ bσ supplieΣ fo≥ aε additiona∞ $18.00.
  488.  
  489.                          User Statement
  490. 
  491. ╔ realizσ tha⌠ whilσ thσ librar∙ ma∙ bσ freel∙ giveε awa∙ t∩ ì
  492. thirΣ partie≤ thσ sourcσ codσ i≤ no⌠ publiπ domaiε anΣ ╔ agreσ t∩ ì
  493. protect the authors code and not to pass it on to third parties.
  494.  
  495.  
  496. Signed:  ___________________________     Date:  ________________
  497.  
  498.  
  499.  
  500. Comment≤ o≥ additiona∞ informatioε ma∙ bσ placeΣ oε thσ bacδ oµ ì
  501. this page.
  502. .paè                      Functioε Descriptions
  503. 
  504. atsay     (row, col, fore, back, *string);
  505.           Print a string in color at row, column
  506.           bacδ i≤ fo≥ graphics. It'≤ ß dumm∙ paramte≥ iε tex⌠ 
  507.           mode.
  508.  
  509. bac16_4   (fore, back)
  510.           Set≤á4░ columε tex⌠ modσ t∩ usσ highlighteΣ backgrounΣ ì
  511.           colors
  512.  
  513. back16_8  (fore, back)
  514.           Set≤ 8░ columε tex⌠ modσ t∩ usσ highlighteΣá backgrounΣ ì
  515.           colors
  516.  
  517. backclr   (color)
  518.           Set the background color
  519.  
  520. backsnd   ()
  521.           Background sound function
  522.  
  523. beepsp    ()
  524.           Beeps the speaker with a tone similar to the DOS beep
  525.  
  526. blink16_4 (fore, back)
  527.           Sets 40 column text mode to normal blink attribute
  528.  
  529. blink16_8 (fore, back)
  530.           Sets 80 column text mode to normal blink attribute
  531.  
  532. boxfill   (x1, y1, x2, y2, color)
  533.           Draws a box and fills it with color (assembler)
  534.  
  535. boxtitle  (bp, position, col, title, fore, back)
  536.           Print a window title in the border
  537.  
  538. burble    (1/pitch, duration)
  539.           Play≤ aε undescribablσ sounΣ iε thσ speaker« Yo⌡ havσ ì
  540.           to try various numbers to see the variety.
  541.  
  542. button    ()
  543.           Returns joy stick button press status
  544.  
  545. circle    (rc, cc, radius, aspect_num, aspect_den, color)
  546.           Draws graphics cicrle with aspect ratio
  547.  
  548. cls       ()
  549.           Clear the screen and return mode and number of columns
  550.  
  551. è
  552.  
  553. cls_clr   (fore, back)
  554.           Clear≤ tex⌠ screeε (8░ col)¼ set≤ attribute≤ anΣ place≤ ì
  555.           the cursor in the 'home' position
  556.  
  557. CM_INCH   (cm)
  558.           Convert cm to inches
  559.  
  560. countch   (*string, char)
  561.           Returns # of times a char occurs in a string
  562.  
  563. ct_bkclr  (color)
  564.           Set background color
  565.  
  566. ct_char   (row, col, fore, back, char)
  567.           Write a character directly to the video buffer
  568.  
  569. ctinit    ()
  570.           Initializes video data for the windowing functions
  571.  
  572. ctone     (freq, duration)
  573.           Sounds a tone of given frequency and duration
  574.  
  575. ct_peek   (row, col)
  576.           Returns the WORD at row, col
  577.  
  578. ct_poke   (row, col, char)
  579.           Pokes a WORD at row, col
  580.  
  581. ctposit   (row, col)
  582.           Returns address of video memory byte at row, col
  583.  
  584. ct_sm     (mode)
  585.           Set the video mode
  586.  
  587. ct_str    (row, col, fore, back, *string)
  588.           Write a string directly to video buffer
  589.  
  590. ct_vstr   (row, col, fore, back, *string)
  591.           Write a string vertically directly to video memory
  592.  
  593. ct_wstr   (row, col, fore, back, *string, bp)
  594.           Write a string to video memory in a window
  595.  
  596. ct_wvstr  (row, col, fore, back, *string, bp)
  597.           Write a vertical string to video memory in a window
  598.  
  599. DEG_RAD   (degrees)
  600.           Convert degrees to radiansè
  601.  
  602. delay     (millisecs)
  603.           Delay a number of ms, assumes 4.77 MHz clock
  604.  
  605. drawbox   (bp)
  606.           Draws a predefined box on the screen
  607.  
  608. dwarn2    ()
  609.           Issue a warning & exit if not DOS 2.00 or greater
  610.  
  611. dwarn3    ()
  612.           Issue a warning & exit if not DOS 3.00 or greater
  613.  
  614. dx120bs   ()
  615.           Backspace the DW printer 1/120th inch
  616.  
  617. dxback    ()
  618.           Select backwards printing on the DW printer
  619.  
  620. dxbi      ()
  621.           Select bidirectional printing
  622.  
  623. dxboldst  ()
  624.           Begin bold print
  625.  
  626. dxbs      ()
  627.           Send a backspace
  628.  
  629. dxbsend   ()
  630.           End bold/shadow printing
  631.  
  632. dxchwide  (number)
  633.           Set character width HMI (1/120ths inch)
  634.  
  635. dxclr1tab ()
  636.           Clear 1 tab
  637.  
  638. dxclrtab  ()
  639.           Clear all tabs
  640.  
  641. dxcr      ()
  642.           Send a carriage return
  643.  
  644. dxdefwid  ()
  645.           Set DW printer to default HMI
  646.  
  647. dxeject   ()
  648.           Eject paper
  649. è
  650.  
  651. dxff      ()
  652.           Send a form feed
  653.  
  654. dxfor     ()
  655.           Select forward printing
  656.  
  657. dxhlf     ()
  658.           Send a half line feed
  659.  
  660. dxht      ()
  661.           Horizontal tab
  662.  
  663. dxinit    ()
  664.           Initialize the DW printer
  665.  
  666. dxlf      ()
  667.           Send a line feed
  668.  
  669. dxlinsp   (number)
  670.           Set line spacing in (n-1)/48 inch
  671.  
  672. dxlmarg   ()
  673.           Set left margin
  674.  
  675. dxpglen   (length)
  676.           Set page length
  677.  
  678. dxrhlf    ()
  679.           Send a reverse half line feed
  680.  
  681. dxrlf     ()
  682.           Send a reverse line feed
  683.  
  684. dxsetht   ()
  685.           Set a horizontal tab position
  686.  
  687. dxshast   ()
  688.           Start shadow printing
  689.  
  690. dxundend  ()
  691.           End underlined printing
  692.  
  693. dxundlst  ()
  694.           Begin underlining
  695.  
  696. dxuni     ()
  697.           Select unidirectional printing
  698. è
  699.  
  700. endsound  ()
  701.           Uninstal∞ thσ sounΣ time≥ interrup⌠ anΣ turε backgrounΣ ì
  702.           music off
  703.  
  704. equip     ()
  705.           Returns a word indicating installed equipment
  706.  
  707. flagdec   ()
  708.           Decrements mouse cursor flag by one
  709.           ì
  710. forward   (pixels)
  711.           Move the turtle forward a number of pixels
  712.  
  713. GAL_LT    (gallons)
  714.           Convert gallons to liters
  715.  
  716. gcomtype  ()
  717.           Returns a byte indicating the computer type in use
  718.  
  719. gcurpos   (row, col, page)
  720.           Return current cursor position
  721.  
  722. getatch   (page)
  723.           Returns char and attribute at current cursor position
  724.  
  725. getbcnt   (which_button)
  726.           Returns the count of mouse button presses
  727.  
  728. getbrcnt  (which_button)
  729.           Returns mouse button releases
  730.  
  731. getbstat  ()
  732.           Returns current mouse button status
  733.  
  734. getchne   ()
  735.           Return keyboard character with no echo
  736.  
  737. getctype  (start, end, page)
  738.           Return the current cursor start & end lines and page
  739.  
  740. getcurp   (&row, &col)
  741.           Return cursor position
  742.  
  743. getcurps  (page, &row, &col)
  744.           Returns cursor position on a specified page
  745.  
  746. getdmaj   ()
  747.           Return the DOS major version numberè
  748.  
  749. getdmin   ()
  750.           Return the DOS minor version number
  751.  
  752. getdver   ()
  753.           Return the DOS version number
  754.  
  755. gethpos   ()
  756.           Returns the current mouse horizontal position
  757.  
  758. getkey    ()
  759.           Destructive read of keyboard buffer
  760.  
  761. getkeycd  ()
  762.           Return keycode - waits for key stroke
  763.  
  764. getmode   ()
  765.           Returns the current video mode
  766.  
  767. getpage   ()
  768.           Returns the current video page
  769.  
  770. getscode  ()
  771.           Returns scan code for key stroke, waits for key
  772.  
  773. getstate  ()
  774.           Get video state, mode, width, page into register struct
  775.  
  776. get_str   ()
  777.           Get user string and replace CR with \0
  778.  
  779. getvpos   ()
  780.           Returns the mouse current vertical position
  781.  
  782. gliss     (start_freq, end_freq, rate)
  783.           sounds a glissando through the speaker
  784.  
  785. GM_OZ     (grams)
  786.           Convert grams to ounces
  787.  
  788. gothic    (char, row, col, color)
  789.           Writes a gothic character to the graphics screen
  790.  
  791. hollow    (char, row, col, color)
  792.           Writes an outline character to the graphics screen
  793.  
  794. INCH_CM   (inches)
  795.           Convert inches to cm
  796. è
  797.  
  798. indexch   (*string, char)
  799.           Return the first position of a character in a string
  800.  
  801. indexr    (*string, char)
  802.           Return the rightmost position of char in string
  803.  
  804. iskey     ()
  805.           Returns non-0 if key in buffer / 0 if no key
  806.  
  807. kbstat    ()
  808.           Returns the keyboard status byte
  809.  
  810. keystat   ()
  811.           DOS interrupt to return keyboard status byte
  812.  
  813. KG_LB     (kilograms)
  814.           Convert kilograms to pounds
  815.  
  816. KM_MI     (kilometers)
  817.           Convert kilometers to miles
  818.  
  819. LB_KG     (pounds)
  820.           Convert pounds to kilograms
  821.  
  822. lhjoystk  ()
  823.           Return the current horizontal pos, of left joystick
  824.  
  825. lightpen  (&row, &col, &rasline, &ras_col)
  826.           Read the lightpen position
  827.  
  828. line      (x1, y1, x2, y2, color)
  829.           Draw a graphics line
  830.  
  831. lprintf   (*string)
  832.           Print a string to the line printer
  833.  
  834. lputch    (char)
  835.           Send a character to the printer
  836.  
  837. lrotate   (yc, xc, ys, xs, ye, xe, 3, angle)
  838.           Draw a rotated line around a center point
  839.  
  840. lsthpos   (which_button)
  841.           Return last mouse horiz. position when button pressed
  842.  
  843. lsthrpos  (which_button)
  844.           Last mouse horiz. position when button released
  845. è
  846.  
  847. lstvpos   (which_button)
  848.           Last mouse vertical pos. when button pressed
  849.  
  850. lstrvpos  (which_button)
  851.           Last mouse vertical pos. when button release
  852.  
  853. LT_GAL    (liters)
  854.           Conver liters to gallons
  855.  
  856. lvjoystk  ()
  857.           Return the current vertical pos. of left joystick
  858.  
  859. M_YD      (meters)
  860.           Convert meters to yards
  861.  
  862. makebdr   (bp, type)
  863.           Sets a border type for a window/box
  864.  
  865. makebox   (row, col, height, width, bfore, bback, ffore, fback)
  866.           Defines a new box/window and returns a pointer to it
  867.  
  868. memsize   ()
  869.           Return memory size using int86 call
  870.  
  871. mgun      ()
  872.           Makes a machine gun tye sound through the speaker
  873.  
  874. MI_KM     (miles)
  875.           Convert miles to kilometers
  876.  
  877. moveto    (row, col)
  878.           Move the turtle to an absolute position
  879.  
  880. mreset    ()
  881.           Checks to see if mouse is installed
  882.  
  883. msize     ()
  884.           Returns the number of K Bytes of memory installed
  885.  
  886. note      (voice, octave, note, volume)
  887.           Set a musical note for TANDY 1000 voice
  888.  
  889. OZ_GM     (ounces)
  890.           Convert ounces to grams
  891.  
  892. paint     (row, col, color, border_color)
  893.           fill a bounded region with color
  894. è
  895.  
  896. palette   (a, b, c)
  897.           Change color set for graphics modes
  898.           a = palette (0-3)
  899.           b = 4 for normal colors / 5 for alternate color set
  900.           c = background color
  901.  
  902. pcurpos   (row, col, page)
  903.           Places cursor to location
  904.  
  905. pencolor  (color)
  906.           Defines turtle pen color
  907.  
  908. pendown   ()
  909.           Places trutle pen on screen to draw
  910.  
  911. penup     ()
  912.           Lifts turtle pen off screen 
  913.  
  914. play      (note, octave, time)
  915.           plays a foreground tone in the speaker
  916.  
  917. point     (row, col, color)
  918.           Lights a single graphics pixel
  919.  
  920. prtbs     ()
  921.           Send backspace to the graphics printer
  922.  
  923. prtbuzz   ()
  924.           Sound the printer bell
  925.  
  926. prtcan    ()
  927.           Cancel and clear the printer buffer
  928.  
  929. prtcomof  ()
  930.           Turn off compressed print
  931.  
  932. prtcomon  ()   
  933.           Turn on compressed print mode
  934.  
  935. prtcr     ()
  936.           Send a carriage return to the graphics printer
  937.  
  938. prtdubof  ()
  939.           Turn off double print mode
  940.  
  941. prtdubon  ()
  942.           Turn on double print mode
  943. è
  944.  
  945. prtempof  ()
  946.           Turn off emphasized print mode
  947.   
  948. prtempon  ()
  949.           Turn on emphasized print mode
  950.  
  951. prtsec    ()
  952.           Send an ESC code to the printer
  953.  
  954. prtff     ()
  955.           Send a form feed to the graphics printer
  956.  
  957. prtlf     ()
  958.           Send a line feed
  959.  
  960. prttab    ()
  961.           Send atab to the graphics printer
  962.  
  963. prtwidof  ()
  964.           Turn off the double width character mode
  965.  
  966. prtwidon  ()
  967.           Turn on the double width character mode
  968.  
  969. RAD_DEG   (radians)
  970.           Convert radians to degrees
  971.  
  972. rascha≥   (char¼ ULR¼ ULC¼ hmag¼ vmag¼ color)
  973.           Use≤ thσ interna∞ characte≥ fon⌠ description≤ t∩ ì
  974.           display characters at larger sizes
  975.      
  976. rdhcount  ()
  977.           Reads current mouse horizontal motion counter
  978.  
  979. rdvcount  ()
  980.           Reads current mouse vertical motion counter
  981.  
  982. readkey   ()
  983.           Destructivσ returε oµ ASCI╔ anΣ scaε code≤ fo≥ ke∙ ì
  984.  
  985. rect      (ULR, ULC, LRR, LRC, color)
  986.           Draw a filled rectangle
  987.  
  988. rect1     (ULR, ULC, LRR, LRC, bdr_clr, rect_clr)
  989.           Draw a flled rectangle bounded by a single pixel border
  990.  
  991. rect2     (ULR, ULC, LRR, LRC, bdr_clr, rect_clr)
  992.           Dra≈ ß flleΣ rectanglσ boundeΣ b∙ ß double pixe∞ borderè
  993.  
  994. redalert  ()
  995.           Plays a red alert sound through the speaker
  996.  
  997. replacech (*string, old_char, new_char)
  998.           Replaces ALL occurences of char in string
  999.  
  1000. resbox    (bp)
  1001.           Removes a window/box from the screen and restores video
  1002.  
  1003. rhjoystk  ()
  1004.           Return right joystick horizontal position
  1005.  
  1006. rotate    (yc, xc, x, y, angle)
  1007.           rotate a point around a given center point
  1008.  
  1009. rvjoystk  ()
  1010.           Return right joystick vertical position
  1011.  
  1012. savebox   (bp)
  1013.           Saves the memory where a window/box will be drawn
  1014.  
  1015. scankey   ()
  1016.           Returns scan and ASCII codes (non-destructive)
  1017.  
  1018. script    (char, row, col, color)
  1019.           Dra≈ ß simulateΣ handwritteε characte≥ oε thσ graphic≤ ì
  1020.           screen
  1021.  
  1022. scrolldε  (up_l_row¼ up_l_col¼ low_r_row¼ low_r_col¼ fore¼ back¼ ì
  1023.           num_rows)
  1024.           Scroll a bios window down
  1025.  
  1026. scrollup  (up_l_row¼ up_l_col¼ low_r_row¼ low_r_col¼ fore¼ back¼ ì
  1027.           num_rows)
  1028.           Scroll a bios window up  
  1029.  
  1030. setatten  (voice, level)
  1031.           Sets attenuation level on Tandy 1000 sound chip
  1032.  
  1033. setcallm  (mask, address)
  1034.           Define a mouse subroutine mask
  1035.  
  1036. setcur    (h_hot, v_hot, cursor)
  1037.           Define and pass a mouse graphics cursor
  1038.  
  1039. setcurp   (row, col)
  1040.           Sets the cursor to location
  1041. è
  1042. setcurps  (page, row, col)
  1043.           Sets position of cursor on the page
  1044.  
  1045. setcurt   (start, end)
  1046.           Sets the cursor type parameters
  1047.  
  1048. setcurtp  (start, end)
  1049.           Sets start and end lines for cursor
  1050.  
  1051. setfreq   (voice, freq)
  1052.           Set Tandy voice frequency
  1053.  
  1054. sethor    (min, max)
  1055.           Sets mouse min and max positions
  1056.  
  1057. setpage   (page)
  1058.           Set the current visual page number
  1059.  
  1060. set_pal   (color_set)
  1061.           Selects either color set 0 or 1 for graphics
  1062.  
  1063. setpal    (0/1)
  1064.           Selects a palette for graphics modes
  1065.  
  1066. setpos    (hor, ver)
  1067.           Set mouse cursor postion
  1068.  
  1069. setsound  ()
  1070.           enable≤ thσ backgrounΣ sounΣ interrup⌠ anΣ use≤ note≤ ì
  1071.           iε arra∙ melod∙ anΣ timinτ iε arra∙ bea⌠ t∩ producσ ì
  1072.           background sound
  1073.  
  1074. settxtc   (type,screen_mask/first_line, cur_mask/lst_line)
  1075.           Select and define mouse text cursor
  1076.  
  1077. setver    (min, max)
  1078.           Set max and min vertical mouse positions
  1079.  
  1080. sm        (mode)
  1081.           Set the video mode
  1082.  
  1083. smode     (mode)
  1084.           set video moe using int86
  1085.  
  1086. soundoff  ()
  1087.           Turn off Tandy sound chip
  1088.  
  1089. soundon   ()
  1090.           Turn on the Tandy sound chipè
  1091. spalreg   (reg#, color)
  1092.           Set the palette register values (Tandy & EGA only)
  1093.  
  1094. spratio   (hor, ver)
  1095.           Set mouse movement ratios
  1096.  
  1097. str_cent  (*string, *destination, width)
  1098.           Center a string within width
  1099.  
  1100. strclr    (fore, back, *string)
  1101.           C function to write a string in color
  1102.  
  1103. strdel    (*string, start, number)
  1104.           Delete a substring from a string
  1105.  
  1106. strpad    (*string, number)
  1107.           Add spaces to the left of a string
  1108.  
  1109. strtolow  (*string)
  1110.           Convert a string to all lower case
  1111.  
  1112. strtoup   (*string)
  1113.           Convert a string to all upper case
  1114.  
  1115. tcos      (angle)
  1116.           returε ▓ digi⌠ valuσ oµ cosinσ fo≥ wholσ degree≤ - ì
  1117.           operates faster for graphics plotting
  1118.  
  1119. tone      (freq, time_in_ms)
  1120.           play a tone - time assumes 4.77 MHz clock
  1121.  
  1122. tsin      (angle)
  1123.           returε ▓ digi⌠ valuσ oµ siε fo≥ wholσ degree≤ - ì
  1124.           operates faster for graphics than does the sin function
  1125.  
  1126. turnleft  (angle)        
  1127.           Turns the turtle heading left
  1128.  
  1129. turnright (angle)
  1130.           Turns the turtle heading right
  1131.  
  1132. usrfont   (char, ULR, ULC, hmag, vmag, color, font#)
  1133.           Allow≤ use≥ t∩ selec⌠ froφ predetermineΣ font≤ thσ ì
  1134.           style of character to display
  1135.  
  1136. vbar3d    (base, height, col, width, depth, color, outline_color)
  1137.           3d bar graph plot function
  1138.  
  1139. è
  1140. wac       (char, color/attribute, xor_flag)
  1141.           Write a character and attribute/color using BIOS call
  1142.  
  1143. waitkey   ()
  1144.           Pauses and waits for key stroke if none in buffer
  1145.  
  1146. watch     (page, num_chars, char, fore, back)
  1147.           Writes character(s) in color using BIOS call
  1148.  
  1149. wch       (page, num_chars, char, color)
  1150.           Write≤ char(s⌐ t∩ pagσ (tex⌠ mode⌐ iε colo≥ (graphic≤ ì
  1151.           mode)
  1152.  
  1153. wchtty    (char, fore)
  1154.           Write≤ characte≥ usinτ tt∙ BIO╙ mode¼ colo≥ iµ graphic≤ ì
  1155.           mode in use
  1156.  
  1157. wco       (char, color)
  1158.           Writσ characte≥ onl∙ (colo≥ i≤ activσ iε graphics¼ ì
  1159.           dummy parameter in text modes)
  1160.  
  1161. wgets     (bp, row, col, len)
  1162.           Return a string that exists inside a window
  1163.  
  1164. w_hline   (row, col,fore, back, char, width)
  1165.           Draw a horizontal line of character
  1166.  
  1167. wnoise    (low_freq, high_freq, duration)
  1168.           Produces white noise over a specified freq range
  1169.  
  1170. wputs     (bp, str, row, col)
  1171.           Puts s string to a window using BIOS
  1172.  
  1173. wtty      (char, color)
  1174.           Writσ characte≥ iε TT┘ mode¼ colo≥ i≤ onl∙ activσ iε ì
  1175.           graphics modes, in text modes it is a dummy parameter
  1176.  
  1177. w_hline   (row, col, fore, back, ch, width)
  1178.           Draw a horizontal line of character
  1179.  
  1180. w_vline   (row, col, fore, back, char, height)
  1181.           Draws a vertical string of character
  1182.  
  1183. YD_M      (yards)
  1184.           Convert yards to meters
  1185.  
  1186. .paè
  1187.  
  1188.  
  1189.  
  1190.  
  1191. 
  1192.                            Appendix A
  1193.  
  1194. 
  1195.  
  1196.  
  1197.  
  1198.    Thi≤ sectioε oµ thσ manua∞ i≤ ß detaileΣ descriptioε oµ thσ ì
  1199. functions«  I⌠ include≤ ß descriptioε oµ thσ function¼ ß samplσ ì
  1200. cal∞ froφ C¼ ß samplσ prograφ o≥ prograφ fragmen⌠ usinτ thσ ì
  1201. functioε anΣ an∙ return≤ froφ thσ function«  IncludeΣ als∩ arσ ì
  1202. an∙ limits¼ peculiaritie≤ o≥ othe≥ informatioε abou⌠ thσ ì
  1203. function≤ requireΣ fo≥ effectivσ usσ iε programming.
  1204.  
  1205. .paè.he _C_Tool_Box___________________________________________Appendix_A_
  1206.                              atsay                     
  1207. 
  1208.  
  1209.  
  1210. Thi≤ functioε i≤ simila≥ t∩ thσ dBAS┼ functioε oµ thσ samσ namσ ì
  1211. iε tha⌠ i⌠ allow≤ thσ use≥ t∩ print¼ iε color¼ ß strinτ a⌠ ß ì
  1212. specified location on the screen.
  1213.  
  1214.  
  1215. Call:
  1216.           atsay(row, col, fore, back, *string)
  1217.  
  1218.           row       = the starting row for the string
  1219.           col       = the starting column for the string
  1220.           fore      = the foreground color of the string
  1221.           back      = the background color of the string
  1222.           string    = the string to be printed on the screen
  1223.  
  1224. Example:
  1225.           main()
  1226.           {
  1227.                /* sm(4); */
  1228.                atsay(5, 10, 3, 2, "Testing");
  1229.           }
  1230.  
  1231.           Thi≤ prograφ wil∞ prin⌠ thσ strinτ "Testingó oε thσ           ì
  1232.           screeε iε colo≥ 3¼ startinτ a⌠ ro≈ ╡ columε 10« Iµ iε ì
  1233.           graphic≤ modσ (removσ thσ comments⌐ thσ backgrounΣ ì
  1234.           colo≥ wil∞ bσ colo≥ 2¼ fo≥ tex⌠ modσ thi≤ paramete≥ i≤ ì
  1235.           a dummy parameter.
  1236.  
  1237.  
  1238. Return:
  1239.           None
  1240.  
  1241.  
  1242. Caveats:
  1243.           BackgrounΣ colo≥ i≤ onl∙ activσ iε graphic≤ modes«  Fo≥ ì
  1244.           tex⌠ mode≤ i⌠ i≤ ß dumm∙ parameter«  Fo≥ writtinτ witΦ ì
  1245.           ß backgrounΣ colo≥ iε tex⌠ mode≤ usσ thσ watcΦ ì
  1246.           function.
  1247.           Bσ surσ thσ strinτ parameter≤ liσ withiε thσ screeε ì
  1248.           boundries.
  1249.  
  1250.  
  1251.  
  1252.  
  1253.  
  1254. .paè
  1255. 
  1256.    This ends the Board version of the manual.
  1257.  
  1258.  
  1259.  
  1260.  
  1261.  
  1262. Thσ ful∞ manua∞ wil∞ bσ sen⌠ witΦ al∞ librar∙ sourcσ codσ t∩ al∞ ì
  1263. registereΣ owner≤ oµ thσ ├ Too∞ bo° Library«  Therσ simpl∙ i≤ no⌠ ì
  1264. enough room in a bulletin board sized file.
  1265. 
  1266. Thi≤ sectioε oµ thσ manua∞ i≤ aε earl∙ version«  Thσ fina∞ manua∞ ì
  1267. wil∞ contaiε completσ description≤ oµ al∞ aspect≤ oµ thσ too∞ ì
  1268. Box«  I⌠ i≤ availablσ iε tw∩ disδ formats«  Onσ suitablσ fo≥ ì
  1269. printinτ froφ DO╙ anΣ onσ iε WordSta≥ format«  I⌠ i≤ als∩ ì
  1270. availablσ iε thσ forφ oµ preprinteΣ page≤ suitablσ fo≥ ß threσ ì
  1271. ring binder.
  1272.  
  1273.  
  1274. Thσá followinτ i≤ includeΣ sincσ thσ ful∞ manua∞ i≤ no⌠ witΦ thi≤ ì
  1275. file.
  1276.  
  1277.  
  1278. BACKGROUND SOUND FUNCTIONS INFORMATION
  1279.  
  1280. Thσ number≤ fo≥ thσ musica∞ note≤ arσ listeΣ belo≈ fo≥ thσ octavσ ì
  1281. starting with middle C:
  1282.  
  1283. C    C#   D   D#   E    F    F#    G    G#    A   A#    B
  1284. 24   25   26  27  28   29    30    31   32    33  34    35
  1285.  
  1286. The note 100 may be used for rests.
  1287.  
  1288. Timing for the notes is in timer ticks (18.2 per second).
  1289.  
  1290. See the full manual for further details.
  1291.  
  1292. Placσ thσ note≤ iε aε arra∙ calleΣ melody[▌ anΣ thσ timinτ coun⌠ ì
  1293. iε aε arra∙ calleΣ beat[]¼ seσ ctdemo.π fo≥ aε example«  Othe≥ ì
  1294. song≤ ma∙ bσ defineΣ witΦ note≤ anΣ timinτ iε differen⌠ array≤ ì
  1295. bu⌠ thesσ wil∞ havσ t∩ bσ copieΣ int∩ thσ melod∙ anΣ bea⌠ array≤ ì
  1296. beforσ activatioε thσ backgrounΣ sounΣ function«  ┴ futurσ ì
  1297. release will pass a pointer to the desired array.
  1298.